Computer-aided optimal design for flexible cable in aerospace products based on dynamic analogy modeling

Due to large, complex deformations, the accurate design of cables has become a major problem in the manufacturing of aerospace products. The current design method often leads to large products, uncertain centroids, and poor reliability. To solve these problems, a computer-aided optimal design method for flexible cables was proposed based on dynamic analogy modeling. A nonlinear optimization model was established by combining Cosserat theory and the minimum potential energy principle. The total deformation energy was considered as the optimization object, and Euler parameters were used as control variables to describe the cable geometric shape. Considering the length and bending radius requirements, the normalized form of the cable constraints was expressed by the cross-section position and orientation matrix. An efficient method to solve this problem using finite element discretization and the primitive dual interior point method was proposed. A digital wiring module was developed based on an open source geometry kernel system, and a cable geometry test bench was built. To verify our model, a satellite wiring simulation example was implemented using the module, SolidWorks, and the test bench. Our method achieved the optimal design for the cable length and geometric shape. A theoretical and technical foundation for effectively solving the problem of large cable manufacturing errors and realizing the lightweight design of aerospace products was outlined.

www.nature.com/scientificreports/ optimal design. The first issue is how to express the complex constraints of a cable by appropriate mathematical formulas, such as clamps, collision contacts, surfaces, and through-holes. The second issue is how to solve the problem accurately and efficiently to obtain the cable design length and final wiring geometric shape. This study focuses on the computer-aided optimal design of flexible cables, similar to the research in Ref. 19,20 . Both described the energy of cable deformation from the point of view of analytical mechanics based on Cosserat theory. In the former, the cable force based on the energy was deduced and the equilibrium equation based on Newton's law of mechanics was established. In the latter, the equilibrium shape of branch cables was simulated using the idea of nonlinear optimization based on the principle of minimum potential energy. In both studies, only the geometric shape was simulated, but the design parameters, such as the cable length and bending radius, were not optimized from the point of view of product optimization design. To solve this problem, a novel method based on the Cosserat theory is proposed herein to realize the computer-aided optimal design of flexible cables. An energy model to describe the cable balance is established in Sect. 2 based on a variational principle, which accounts for the complex constraints and requirements of the length and bending radius. An efficient large-scale nonlinear optimization algorithm is introduced in Sect. 3 to obtain a reasonable length, bending radius, and spatial geometry of the cable. A flexible cable wiring module is developed in Sect. 4. A satellite wiring simulation example is provided in Sect. 5, which was implemented using the module, SolidWorks, and the test bench to verify our method. Finally, the study is concluded.

Static modeling
Cable spatial geometric shape description. Based on dynamic analogy method, the spatial geometric shape of the cable is formed by displacement and rotation of a cross-section along the centerline 21,22 . Therefore, the geometric shape can be expressed by the cross-section orientation and the shape of the centerline, as shown in Fig. 1.
The cable geometric shape is expressed by the variables (r(s), (d 1 (s), d 2 (s), d 3 (s)) and can be identified by r(s) and C(d 1 (s), d 2 (s), d 3 (s)). r(s) represents the shape of the centerline. C(d 1 (s), d 2 (s), d 3 (s)) is a directional cosine matrix formed by the projection of the moving coordinate system P-d 1 d 2 d 3 relative to the fixed coordinate system O-xyz and represents the cross-section orientation.
Euler parameters are introduced to describe the directional cosine matrix. Their physical meaning is that the arbitrary rotation of a rigid body around a fixed point O can be realized by a single rotation (angle χ) of a rotation axis P(p 1 , p 2 , p 3 ) around that point. This rotation cosine matrix C could be expressed by Eq. (1) 23 . Compared with Euler angles, the Euler parameters can effectively avoid singularities and are suitable for expressing large deformations of cables: The Euler parameters are quaternions, and the definition of quaternions are expressed as follows: The four symbols q 1 , q 2 , q 3 , q 4 are the Euler parameters, and the directional cosine matrix of P-d 1 d 2 d 3 relative to O-xyz can be represented by the Euler parameters as follows: (2) Figure 1. Spatial geometric shape of cable. www.nature.com/scientificreports/ A twisting vector named ω is introduced to express the cable bending and torsion deformation, and its three component expressions in P-d 1 d 2 d 3 are shown as follows: The relationships between each coordinate of P-d 1 d 2 d 3 and ω are as follows: According to Eqs. (3)-(5), the following relationships between ω and the Euler parameters can be deduced: Finite element discretization. The cable is discretized into nodes and elements based on the finite element method. As shown in Fig. 2, the cable is divided into n nodes along the centerline and n-1 elements.
The cable stretching stiffness is very large, and thus, the stretching deformation is neglected. The distance between adjacent nodes are represented by a constant with the symbol l. The Euler parameters are located at the cross-section of the node, and the Euler parameters are unchanged in the element. By linear interpolation in the element, the Euler parameters and derivatives in any element i can be obtained, as shown in Eqs. (7) and (8): The position of element i is denoted by r(q i ), and the orientation of element i is denoted by C i (d 1,i (s), d 2,i (s), d 3,i (s)). The expression of the element position and orientation by the discrete Euler parameters is realized by Eqs. Minimum potential energy principle. Actually, the cable routing design method is to solve the spatial geometric shape in an equilibrium state. According to the minimum potential energy principle of elastic 2l(q 2,j q 4,j + q 1,j q 3,j ) 2l(q 2,j q 4,j + q 1,j q 3,j ) www.nature.com/scientificreports/ mechanics, the real displacement makes the total potential energy of an elastomer take a stationary value, that is, the first-order variation is zero 23 . Therefore, by solving the minimum value problem of the total potential energy of the cable under the boundary condition, the displacement of all the cross-sections with the minimum potential energy can be obtained, and the cable geometric shape in the equilibrium state can be obtained. The total potential energy of the cable is composed of the elastic potential energy produced by elastic strain and gravity. The elastic potential energy is generated by the relative position and orientation change of each cable segment element and is equal to the sum of the bending and torsion potential energies. The gravity potential energy is evenly distributed in each cable element, which is related to the element location. Thus, the total potential energy of the cable can be described by discrete Euler parameters as follows: Cable bending potential energy. As shown in Fig. 3, bending deformation is caused by the angle change between two adjacent elements.
The curvature radius is equal to the radius of the circumferential circle of the triangle formed by three continuous nodes. The cable bending potential energy of element i and i + 1 E bending,i could be calculated as follows: The curvature κ i in Eq. (13) can be calculated as follows: The bending stiffness K b can be calculated as follows: where E is the elastic modulus of the cable material, and R is the radius of the cross-section.
Cable torsion potential energy. The cable torsion deformation consists of a Frenet torsion and a pure material torsion. The Frenet torsion is defined by the geometrical torsion of the centerline, and the pure material torsion shows the position of the material lines relative to the Frenet frames. According to Eq. (5), the cable torsion potential energy is a function of the third twisting vector component ω 3 . As shown in Fig. 4, cable torsion can be expressed by the Euler parameters of adjacent elements, and the torsion potential energy of element i can be expressed as follows: Figure 3. Bending deformation of adjacent elements. www.nature.com/scientificreports/ The torsion stiffness K t can be calculated as follows: where G is the shear modulus of the cable material.
Cable weight potential energy. Gravity, as an external force with a constant direction acting on the cable, has a great influence on the cable deformation. The longer the cable is, the more significant its influence becomes. As shown in Fig. 5, the cable length of each element is denoted as l, gravitational acceleration is denoted as g, and the mass of each element is denoted as m. Thus, the total cable mass is (n-1)m. The cable weight potential energy of element i can be expressed as follows: The mass of each element can be calculated as follows: where ρ is the cable density.

Mathematic model solving
Optimization problem description. In the above section, the spatial geometric shape and potential energy equations of the cable were established, taking the Euler parameters as reference variables. Based on the minimum potential energy principle, the cable spatial geometric shape can be determined by solving the Euler parameters in the equilibrium state. Therefore, the Euler parameters were chosen as the decision variables. For different spatial constraints, Euler parameters of different cross-sections have different forms. The optimization problem of the cable static model is described as follows: Decision variables: Optimization objective: Constraint conditions: where i represents a node, j represents an element, k represents a component of a vector, and κ 0 is the curvature radius requirement, which is determined by the minimum curvature radius. Figure 5. Element weight. www.nature.com/scientificreports/ For a cable with n nodes, there are n − 1 elements, n − 2 bending and torsion potential energy formulas, and n − 1 weight potential energy formulas. The above Euler parameters standardization constraint f j (q) is an internal constraint of the model, and the modulus of the Euler parameters is 1. To normalize the form of the different cable constraints, cross-sectional position and orientation matrices are proposed, denoted as g j (q) and h j (q). The significance of this expression is that, regardless of the constraints, such as boundaries, clamps, through-holes, and contacts, the mathematical expressions of the constraints have specific positions and orientations at different cross-sections. The position and orientation can be expressed using the Euler parameters. Compared to the methods presented in Ref. 19,20 , this method of constraint processing is simpler, eliminating the need to derive different mathematical formulas for different constraints.
Algorithmic design. The optimization model described in the previous section contains both equality and inequality constraints, comprising a nonlinear multi-dimensional optimization problem. We propose a solution algorithm based on the primal-dual interior point method. Firstly, the Euler parameters of each discrete section are obtained. The position and attitude of each section along the arc length of the cable are subsequently calculated according to Eqs. (9) and (10). The flow chart of the algorithm is shown in Fig. 6.
Solving optimization problem. The nonlinear multi-dimensional optimization problem with equality and inequality constraints is one of the most difficult optimization problems in mathematical programming. In this study, the constraints of the static optimization problem are very large, and the equality constraints are nonlinear. To solve this with appropriate accuracy and efficiency, we propose a primal dual-interior point method as the solution algorithm.
The standard form of the nonlinear optimization problem described in Eqs. The determination of the search direction is the key to solving an optimization problem. The feasible direction and descending direction are two important search directions. The former is the direction in which the iteration point satisfies the constraints in the search direction, while the latter is the direction in which the iteration point makes the objective function descend in the search direction. For our optimization problem, the restrictions on the search direction are shown in Fig. 7.   www.nature.com/scientificreports/ At the iteration point x (k) , the search direction d 1 is originally the feasible descent direction of the constraint condition but becomes the infeasible direction under the constraint c(x) ≥ 0; both d 2 and d 3 are feasible directions of the constraint c(x), where d 3 is the feasible descent direction.
Based on the designed feasible descent algorithm, the primitive dual-interior point method can be used to solve Eq. (25). The algorithm steps are described below. More detailed information can be found elsewhere 24 : (1) According to the constraints, a function is constructed and added to the objective function. The new function constructed is called a Lagrange function, expressed as follows: where μ is the obstacle factor. The interior-point method solves the nonlinear optimized Karush-Kuhn-Tucker equation as follows: where ▽f(x) is the derivative of the objective function, ▽c(x) is the Jacobian matrix of the equality constraint, λ and z are the Lagrangian multiplier and the dual variable, respectively, X and Z represent the diagonal matrix, and x represents the diagonal elements.
(2) Equation (27) is linearized using the damped Newton method. The linear equation that is set along the direction (d k x , d k λ , d k z ) at the iteration point (x k , λ k , z k ) is expressed as follows: where W k is the Hessian matrix of the original Lagrangian function φ, and A k is the Jacobian matrix of the equality constraint. The elimination of the search direction of the inequality-constrained multipliers can be obtained using the following equations: (3) After obtaining the search direction, the new iteration point is defined as follows: where α k and α k z are obtained using a linear search method. The next iteration will be performed until the termination condition is satisfied.

Wiring design system development
System design. This system is used to optimize the cable length to guarantee a reasonable bending shape.
In a virtual environment with the digital prototype of a product, the cable routing position and fixed position can be determined according to the electrical wiring diagram. The cable length is designed to determine the spatial geometric shape under different complex spatial constraints.
To solve the static model described by Eq. (25), we must know the geometric parameters (length and radius) and material parameters (elastic modulus, shear modulus, and density). Aside from the length, the other five parameters can be easily obtained if the cable type is known. The cable length is uncertain, but the model requires the length as an input condition. To determine this, we proposed a fast method of cable length acquisition based on the spline curve. This method takes the known fixed positions as data points and draws a spline curve based on these. The initial length of the cable can be calculated by integrating the curve along the arc length. Finally, continuous optimization of the length is carried out based on the requirements of the bending radius and spatial layout.
Fast solution for static model. Figure 8 shows the solution time for different discrete quantities and compares them with those of Ref. 19,20 . The solution time of our method increases approximately linearly with the number of discrete points and is four times more efficient than that of Ref. 20 . Our efficiency is basically the same as that in Ref. 19 , but our model can handle contact constraints and is more complex. Based on the results, the effectiveness of our proposed algorithm and the efficiency meet the requirements of flexible cable digital design.

Rapid surface modeling.
After obtaining the discrete data points of a cable, the cable surface should be drawn to achieve the geometric shape simulation. The determination of the cable geometric shape simulation usually includes two methods, the curve scanning envelope method and the discrete section connection (30) www.nature.com/scientificreports/ method 25 . The principle of the former is to first construct a path through the discrete points based on a spline curve and subsequently generate the surface by scanning the cross-section along the path as long as the crosssection orientation is known. The cable surface rendered by this method is fairly smooth, and thus, we selected this method. Figure 9 shows an example of the cable geometric shape.

Cable routing validation
Routing module development. Based on the flexible cable digital design method mentioned in the above section, the cable digital wiring design module is presented in this section. The module development process is shown in Fig. 10. This module was developed in the Microsoft Visual Studio 2018 (VS2018) environment under the Windows 10 operating system using the C++ language and the existing virtual assembly system 4 . The interface of this module was based on the MFC (Microsoft Foundation Classes) basic class library. The API (Application Programming Interface) provided by AMPL was used to solve the static model. The cable geometric modeling was realized based on an open source geometric kernel system, named Open Cascade (OCC). Data management of the wiring module was implemented using the C++ file operation class fstream.
The cable designer first determines the material use and wiring relationship of the cable according to the digital model of the product and the electrical schematic diagram, after which the key points of the cable are determined based on the wiring specifications. This module automatically provides the initial length of the cable through the position of the key points of the cable and displays the geometry of the cable in three dimensions. The designer can perform interference and bending radius checks. If the results do not meet the requirements, the cable wiring length is amended and rewired until all wiring requirements are met. The module subsequently records the cable wiring path and material usage information. If there is significant interference in the wiring result of a cable within the allowable length range, the cable designer is required to receive feedback from the product design department to optimize the electrical connection position of the product. After completing the wiring design of an aerospace product, the design results are output. The output of the module includes the 3D wiring geometric shape, path information, length, and material usage information.

Model validity experiment.
To verify the accuracy and validity of our model, a cable geometry test rig was built according to the internal structure model of a satellite, as shown in Fig. 11. There were several holes on the plane of the test bench to simulate the constraints of the passing holes. The two ends of the cable were fixed by the positioning joint. Figure 12 shows a multi-core copper cable. Based on the different lengths of the cables, the cable space shapes were tested under certain boundary conditions, and the results were compared with those obtained by the static model.  www.nature.com/scientificreports/   www.nature.com/scientificreports/ The physical parameters and boundary conditions of the multi-core copper cable are given in Table 1.
As shown in Fig. 13a-d, under the same boundary conditions but with different lengths, L a = 55 cm, L b = 64 cm, L c = 73 cm, and L d = 82 cm, the bending degree of the cable will gradually increase under the action of self-weight and internal forces.
Using the modeling method proposed in this study, the cable spatial geometric shape was calculated. As shown in Fig. 14, the shape of the cable centerline was drawn in Matlab. The simulated cable curve was consistent with the experimental results, which proved the validity of the proposed model and algorithm.

Application cases.
To further illustrate the validity of the flexible cable digital design method proposed in this paper, the functions of the developed cable digital wiring design module were introduced with a wiring process of a satellite simulator, and the relevant results were verified. The steps were as follows: (1) In a 3D CAD environment, based on the requirements of the electrical connection and wiring experience, the cable connector model was determined, and the products and cable connectors were assembled. The assembly model of the satellite simulator was transformed into the model data format (.step) required by our wiring system. Figure 15 shows the 3D model of the satellite simulator.  www.nature.com/scientificreports/ (2) According to the requirement of the electrical schematic and wiring diagrams, the cable materials were determined, and the material library was established. (3) First, a cable was wired. The cable name was established through the new cable interface, and the material name was selected to establish the cable. In the constraint management interface of the system, the circular section of the cable connector was selected as the constraint surface, and the direction constraint of the cable connection was defined. (4) By choosing the appropriate cable connector using a mouse to build the cable, the program completed the calculation of the cable static model and generated the cable surface in real time. Figure 16 shows the result of the single cable wiring. (5) The bending radius of the generated cable was tested. When the bending radius exceeded the user's set value, the length of the current cable was acquired and modified to facilitate re-wiring.  www.nature.com/scientificreports/ (6) Steps 1-5 were repeated until all cables were wired. During the wiring, the interference was monitored at all times. When the interference occurred, the cable length was changed and rearranged. Figure 17 shows the results of the 3D wiring after all cable designs were completed.

Digital wiring verification.
To illustrate the correctness of the above wiring case, further comparative verification was carried out. First, combined with the digital prototype of the satellite simulator, wiring was carried out in the wiring design plugin provided by the SolidWorks software. By selecting the end circle section center of the cable connector as the connection point of the cable, wiring was carried out using the automatic wiring function. The wiring result in SolidWorks (version: 2019 SP5.1; URL: https:// www. solid works. com) is shown in Fig. 18. The length of each cable was determined by the SolidWorks measurement function. Meanwhile, wiring experiments were carried out on the test bench. The wiring results were recorded using a camera, and the results are shown in Fig. 19.
The wiring results from SolidWorks and the wiring shape test bench were compared in the flexible cable digital wiring design module. Comparing the wiring results in the three environments, as shown in Table 2, the average wiring length of the proposed method was 12.2 mm longer than that of the wiring test bench, corresponding to a difference of 7.25%. The wiring length in SolidWorks was 24.98 mm longer than the actual result, and the difference was 13.55%. The results showed that the design length of the cable decreased by 6.3%. The digital design method of the flexible cables proposed in this paper could effectively reduce the cable design length and realize the lightweight design of products.

Conclusion
In this study, a computer-aided optimal design method for flexible cables was proposed based on a variational principle. Optimization of the geometric parameters, such as the length and bending radius, of flexible cables in aerospace products was achieved. The problems caused by the wiring design of existing CAD software, such  www.nature.com/scientificreports/ as the large product quality, uncertain centroid, and poor reliability, were resolved. The main conclusions were as follows:   www.nature.com/scientificreports/ (1) The rapid solution of the cable geometry was achieved. The algorithm was developed by AMPL and Visual Studio, which guaranteed its efficiency. Our solution speed was four times greater than that of Ref. 20 . Our efficiency was similar to that of Ref. 19 , but our model could handle contact constraints and more complex shapes. From the results, the effectiveness and efficiency of our proposed algorithm met the requirements of flexible cable digital design. (2) The function of the digital wiring module was verified by an example, and the wiring and experimental results were compared and analyzed. The results showed that the design length of the cable decreased by 6.3% to achieve the minimum bending radius. (3) From the above analysis, the model and algorithm proposed in this paper could effectively solve the problem of inaccurate design parameters of the cable (large length and bending radius), and it could handle a variety of complex constraints. The algorithm presented by Ref. 20 could only simulate the cable shape based on the boundary conditions. While the algorithm presented in Ref. 20 could find a reasonable route, it could not optimize parameters such as the length and bending radius. Ref. 19 solved the problem of branch wiring from an optimization perspective. However, it could not account for contact constraints and optimize the length and bending radius.
In summary, compared with traditional commercial design software, the flexible cable digital design method proposed in this study can effectively reduce the length of cable design, increase product quality, and improve the reliability of aerospace product design. It lays a theoretical and technical foundation for effectively solving the problem of a large error in the cable manufacturing and achieving lightweight designs of products. However, the algorithm should be further expanded and studied as follows: (1) Efficient and robust cable dynamics modeling and a numerical calculation method should be studied.
(2) Computer-aided design and assembly of flexible cable bundles should be developed. www.nature.com/scientificreports/